<include file="Public:header"/>

<div class="mainbox" style="width:800px;height:1400px;">
    <br/>
    <div style="width:800px;height:1300px;">
        <h1>北京化工大学教职工动火证申请信息填写</h1><br/><br/>

        <form style="text-align:left;" action="{:U('Home/Permit/save')}" method="POST" name="" id="permit-form" enctype="multipart/form-data">

            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>申请动火的校内单位名称:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="apply_name">
            </div>

            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>单位负责人:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="apply_incharge">
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>负责动火施工单位名称:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="construct_name">
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>施工单位负责人:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="construct_incharge">
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>特种作业操作证（没有无需填写）:
                </label>
                <div class="col-sm-10" style="width:78%;">
                    <input type="radio" name="special_cer" value="1" checked/>有&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;
                    <input type="radio" name="special_cer"value="2"  />无
                </div>
            </div>


            <div class="col-sm-11 form-group" id="special-id" >
                <label for="inputEmail3" class="col-sm-2 control-label">证号:</label>
                <div class="col-sm-10" style="width:78%;">
                    <input type="text" class="form-control" id="inputEmail3" name="special_id">
                </div>
            </div>


            <div class="col-sm-11 form-group">
                <label for="inputEmail3" class="col-sm-3 control-label">有效期至:</label>
                <div class="col-sm-4" style="margin-left:-74px;margin-top: -5px;">
                    <input type="text" value="{$now}" name="special_time" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd HH:mm:ss' })">
                </div>
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>动火操作人员:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="operator_name">
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>动火作业的原因:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="operator_reason">
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>动火部位及环境:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="operator_localtion">
            </div>


            <div class="form-group" style="line-height:55px;">
                <label for="exampleInputFile" class="col-sm-3 control-label">上传施工方案图:</label>
                <div class="col-sm-9" style="margin-top:18px;">
                    <input type="file" id="exampleInputFile" name="photo">
                </div>
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>动火作业种类:</label>
                <input type="text" class="form-control" id="exampleInputEmail1" name="operator_type">
            </div>


            <div class="col-sm-11 form-group">
                <label for="exampleInputEmail1"><span style="color:#F00">*</span>动火作业开始时间:</label><br/>
                <div class="col-sm-4" style="margin-left:145px;margin-top: -32px;">
                    <input type="text" value="{$now}" name="operator_starttime" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd HH:mm:ss' })" />
                </div>
            </div>

    <div class="col-sm-11 form-group">
        <label for="exampleInputEmail1"><span style="color:#F00">*</span>动火作业截止时间:</label><br/>
        <div class="col-sm-4" style="margin-left:145px;margin-top: -32px;">
            <input type="text" value="{$now}" name="operator_endtime" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd HH:mm:ss' })">
        </div>
    </div>


    <div class="col-sm-11 form-group">
        <label for="name"><span style="color:#F00">*</span>动火作业采取的消防安全措施:</label>
        <textarea class="form-control" rows="3" style="width:650px;height:150px;" name="operator_measure"></textarea>
    </div>
    <div class="col-sm-3 form-group">
        <button type="button" class="btn btn-info btn-lg" style="margin-left:50px;" onclick="javascript:history.go(-1)">
            <span class="glyphicon glyphicon-arrow-left" aria-hidden="true"></span> 上一步
        </button>
    </div>

    <div class="col-sm-3 form-group">
        <button type="submit" class="btn btn-info btn-lg" style="margin-left:20px;">
            <span class="glyphicon glyphicon-ok-sign" aria-hidden="true"></span> &nbsp;&nbsp;提交申请&nbsp;&nbsp;&nbsp;
        </button>
    </div>

    <div class="col-sm-3 form-group">
        <button type="button" class="btn btn-info btn-lg" style="margin-left:40px;" onclick="javascript:drift()">
            <span class="glyphicon glyphicon-download" aria-hidden="true"></span> 暂存至草稿箱
        </button>
    </div>

    </form>


</div>
</div>

</div>


<!-- 2 加载jQuery库，同时加载该库必须在加载bootstrap.min.js之前  -->
<script src="http://cdn.bootcss.com/jquery/1.11.3/jquery.min.js"></script>
<!-- 3 加载bootstrap核心 -->
<script src="__ROOT_/js/bootstrap.min.js"></script>
<script>
    $(document).ready(function(){

        var check_agree = $("input[name=special_cer]:checked");
//        alert(check_agree.val());
        if (1==check_agree.val()){
            $("#special-id").show();
        }else if(2==check_agree.val()){
            $("#special-id").hide();
        }

        $("input[name=special_cer]").click(function(){
            if (1==$(this).val()){
                $("#special-id").show();
            }else if(2==$(this).val()){
                $("#special-id").hide();
            }
        });
    });
    function drift() {
        $('#permit-form').attr('action', "{:U('Home/Permit/save?drift=1')}");
        $('#permit-form').submit();
    }
</script>

</body>
</html>
